<div class="position-sticky sidebar-sticky" style="top: 56px; height: calc(100vh - 56px); overflow-y: auto;">  
    <ul class="nav flex-column">  
        <li class="nav-item">  
            <a class="nav-link {% if request.resolver_match.url_name == 'dashboard' %}active{% endif %}" href="{% url 'dashboard' %}">  
                <i class="fas fa-home"></i> 仪表盘  
            </a>  
        </li>  
        <li class="nav-item">  
            <a class="nav-link {% if 'wallet' in request.resolver_match.url_name %}active{% endif %}" href="{% url 'wallet_list' %}">  
                <i class="fas fa-wallet"></i> 钱包管理  
            </a>  
        </li>  
        <li class="nav-item">  
            <a class="nav-link {% if 'transaction' in request.resolver_match.url_name %}active{% endif %}" href="{% url 'transaction_list' %}">  
                <i class="fas fa-exchange-alt"></i> 交易记录  
            </a>  
        </li>  
        <li class="nav-item">  
            <a class="nav-link {% if 'category' in request.resolver_match.url_name %}active{% endif %}" href="{% url 'category_list' %}">  
                <i class="fas fa-tags"></i> 分类管理  
            </a>  
        </li>  
        <li class="nav-item">  
            <a class="nav-link {% if request.resolver_match.url_name == 'statistics' %}active{% endif %}" href="{% url 'statistics' %}">  
                <i class="fas fa-chart-bar"></i> 统计分析  
            </a>  
        </li>  
    </ul>  

    <h6 class="sidebar-heading d-flex justify-content-between align-items-center px-3 mt-4 mb-1 text-muted">  
        <span>快捷操作</span>  
    </h6>  
    <ul class="nav flex-column mb-2">  
        <li class="nav-item">  
            <a class="nav-link" href="{% url 'transaction_add' %}">  
                <i class="fas fa-plus-circle"></i> 添加交易  
            </a>  
        </li>  
        <li class="nav-item">  
            <a class="nav-link" href="{% url 'wallet_add' %}">  
                <i class="fas fa-plus-circle"></i> 添加钱包  
            </a>  
        </li>  
        <li class="nav-item">  
            <a class="nav-link" href="{% url 'export_transactions_csv' %}">  
                <i class="fas fa-file-export"></i> 导出数据  
            </a>  
        </li>  
    </ul>  
</div>